package com.my.controller;

import com.my.common.result.R;
import com.my.service.UserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author mars
 * @date 2025-03-03 21:03
 */
@RestController
@RequestMapping("/user")
public class UserController {

//    @Resource(name = "userServiceOne")
//    @Resource(name = "userServiceTwo")
//    @Resource

    @Autowired
//    @Qualifier("userServiceOne")
    @Qualifier("userServiceOne")
    private UserService userService;


    @GetMapping("/getUserName")
    public R<String> getUserName() {
        return R.success(userService.getUserName());
    }
}
